<template>
  <el-form ref="basicInfoForm" :model="info" :rules="rules" label-width="150px">
    <el-row>
      <el-col :span="12">
        <el-form-item label="产品分类" prop="classifiedName">
          <el-input placeholder="请输入仓库名称" v-model="info.classifiedName" />
        </el-form-item>
      </el-col>
      <el-col :span="12">
        <el-form-item label="所属机构" prop="orgId">
          <el-input placeholder="请输入" v-model="info.orgId" />
        </el-form-item>
      </el-col>

      <el-col :span="12">
        <el-form-item label="消息协议" prop="messageProtocol">
          <el-input placeholder="请输入" v-model="info.messageProtocol" />
        </el-form-item>
      </el-col>
      <el-col :span="12">
        <el-form-item label="设备类型" prop="deviceType">
          <el-input placeholder="请输入" v-model="info.deviceType" />
        </el-form-item>
      </el-col>
      <el-col :span="24">
        <el-form-item label="说明" prop="describe">
          <el-input type="textarea" :rows="3" v-model="info.describe"></el-input>
        </el-form-item>
      </el-col>
    </el-row>
  </el-form>
</template>
<script>
export default {
  name: "BasicInfoForm",
  props: {
    info: {
      type: Object,
      default: null
    }
  },
  data() {
    return {
      rules: {
        tableName: [
          { required: true, message: "请输入表名称", trigger: "blur" }
        ],
        tableComment: [
          { required: true, message: "请输入表描述", trigger: "blur" }
        ],
        className: [
          { required: true, message: "请输入实体类名称", trigger: "blur" }
        ],
        functionAuthor: [
          { required: true, message: "请输入作者", trigger: "blur" }
        ]
      }
    };
  }
};
</script>
